/*
 * Copyright (c) 2006-2021, RT-Thread Development Team
 *
 * SPDX-License-Identifier: Apache-2.0
 *
 * Change Logs:
 * Date           Author       Notes
 * 2024-06-25     WangJing       the first version
 */
#ifndef HARDWARE_USER_SERIAL_H_
#define HARDWARE_USER_SERIAL_H_

#include "stdbool.h"
#include "stm32f4xx_hal.h"
#include "rtthread.h"
#include "drv_common.h"

uint8_t * Serial_Buffer(uint8_t index);
void Serial_Transmit(uint8_t index,uint8_t *cmd, uint32_t size);

void ARM1_serial_init(void);
void ARM1_Transmit(uint8_t *cmd, uint32_t size);
uint8_t * ARM1_GetBeffer(void);
uint32_t ARM1_GetIndex(void);

void ARM2_serial_init(void);
void ARM2_Transmit(uint8_t *cmd, uint32_t size);
uint8_t * ARM2_GetBeffer(void);
uint32_t ARM2_GetIndex(void);

void LoRa_serial_init(void);
void LoRa_Transmit(uint8_t *cmd, uint32_t size);
uint8_t * LoRa_GetBeffer(void);
uint32_t LoRa_GetIndex(void);

void Pi_serial_init(void);
void Pi_Transmit(uint8_t *cmd, uint32_t size);
uint8_t * Pi_GetBeffer(void);
uint32_t Pi_GetIndex(void);

void Platform2D_serial_init(void);
void Platform2D_Transmit(uint8_t *cmd, uint32_t size);
uint8_t * Platform2D_GetBeffer(void);
uint32_t Platform2D_GetIndex(void);

#endif /* HARDWARE_USER_SERIAL_H_ */
